#! /usr/bin/perl
#------------------------------------------------
# Author:    kvkrishna
# Created:   Mon Apr 18 13:39:59 IST 2011
# File Name: LogicalOp
# 
# 
# 
# 
#------------------------------------------------
$a = 2 ** 3 ;
$b = 15 ;
printf "%02d\t%04b\n", $a & $b, $a & $b;
printf "%02d\t%04b\n", $a | $b, $a | $b;
printf "%02d\t%04b\n", $a ^ $b, $a ^ $b;
printf "%02d\t%04b\n", $a, ~$a;
